public class Main2 {
    public static void main(String[] args) {
        dfs(0,new StringBuilder());
    }

    private static void dfs(int pos,StringBuilder sb) {
        if (pos == 26) {
            if (!sb.toString().equals("")) {
                System.out.println(sb.toString());
            }
            return;
        }
        // 不选
        dfs(pos + 1,sb);
        // 选
        sb.append((char)(pos + 'a'));
        dfs(pos + 1,sb);
    }
}
